﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="left.aspx.cs" Inherits="DistributedWeb.left" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
   <title>SRM系统</title>
    <script anguage=JavaScript>
        function tupian(idt) {
            var nametu = "xiaotu" + idt;
            var tp = document.getElementById(nametu);
            tp.src = "/images/ico05.gif";//图片ico04为白色的正方形

            for (var i = 1; i < 30; i++) {

                var nametu2 = "xiaotu" + i;
                if (i != idt * 1) {
                    var tp2 = document.getElementById('xiaotu' + i);
                    if (tp2 != undefined)
                    { tp2.src = "/images/ico06.gif"; }//图片ico06为蓝色的正方形
                }
            }
        }

        function list(idstr) {
            var name1 = "subtree" + idstr;
            var name2 = "img" + idstr;
            var objectobj = document.all(name1);
            var imgobj = document.all(name2);


            //alert(imgobj);

            if (objectobj.style.display == "none") {
                for (i = 1; i < 10; i++) {
                    var name3 = "img" + i;
                    var name = "subtree" + i;
                    var o = document.all(name);
                    if (o != undefined) {
                        o.style.display = "none";
                        var image = document.all(name3);
                        //alert(image);
                        image.src = "/images/ico04.gif";
                    }
                }
                objectobj.style.display = "";
                imgobj.src = "/images/ico03.gif";
            }
            else {
                objectobj.style.display = "none";
                imgobj.src = "/images/ico04.gif";
            }
        }
    </script>
</head>
<body>
<table width="198" border="0" cellpadding="0" cellspacing="0" class="left-table01">
  <tr>
    <TD>
		<table width="100%" border="0" cellpadding="0" cellspacing="0">
		  <tr>
			<td width="207" height="55" background="/images/nav01.gif">
				<table width="90%" border="0" align="center" cellpadding="0" cellspacing="0">
				  <tr>
					<td width="25%" rowspan="2"><img src="/images/ico02.gif" width="35" height="35" /></td>
					<td width="75%" height="22" class="left-font01">您好，<span class="left-font02" id="userName">king</span></td>
				  </tr>
				  <tr>
					<td height="22" class="left-font01">
						[&nbsp;<a href="/Hander/hander.ashx?act=logout" target="_top" class="left-font01" id="logout">退出</a>&nbsp;]</td>
				  </tr>
				</table>
			</td>
		  </tr>
		</table>

		<!--  用户管理    -->
		<TABLE width="100%" border="0" cellpadding="0" cellspacing="0" class="left-table03">
          <tr>
            <td height="29">
				<table width="85%" border="0" align="center" cellpadding="0" cellspacing="0">
					<tr>
						<td width="8%"><img name="img8" id="img8" src="/images/ico04.gif" width="8" height="11" /></td>
						<td width="92%">
								<a href="javascript:" target="mainFrame" class="left-font03" onClick="list('8');" >用户管理</a></td>
					</tr>
				</table>
			</td>
          </tr>		  
        </TABLE>
		<table id="subtree8" style="DISPLAY: none" width="80%" border="0" align="center" cellpadding="0" 
				cellspacing="0" class="left-table02">
				<tr>
				  <td width="9%" height="20" ><img id="xiaotu20" src="/images/ico06.gif" width="8" height="12" /></td>
				  <td width="91%"><a href="/SqlAddUser" target="mainFrame" class="left-font03" onClick="tupian('20');">添加用户</a></td>
				</tr>
				<tr>
				  <td width="9%" height="21" ><img id="xiaotu21" src="/images/ico06.gif" width="8" height="12" /></td>
				  <td width="91%"><a href="/SqlList" target="mainFrame" class="left-font03" onClick="tupian('21');">用户信息浏览</a></td>
				</tr>
      </table>
		<!--  用户管理 结束    -->


	  </TD>
  </tr>
  
</table>
    <script src="Scripts/jquery-1.4.1.min.js" type="text/javascript"></script>
    <script type="text/javascript">
        $(document).ready(function () {
            $.get("/Hander/hander.ashx?act=getUserName", function (data) {
                $("#userName").text(data);
            });

        });
    </script>
</body>
</html>
